package com.siss.tenancy.constant;

/**
 * 定义rabbitMq需要的常量
 * @author ygw
 * 2018年9月27日
 */
public class RabbitMqEnum {

	  /**
     * describe: 定义交换机
     * creat_user: ygw
     * creat_date: 2018年9月27日
     **/
    public enum Exchange {
    	MESSAGE_SMS_EXCHANGE_FANOUT("message.sms.exchange.fanout", "手机短信消息分发"),
        MESSAGE_SMS_EXCHANGE_TOPIC("message.sms.exchange.topic", "手机短信消息订阅"),
        MESSAGE_SMS_EXCHANGE_DIRECT("message.sms.exchange.direct", "手机短信点对点"),
        MESSAGE_SMS_EXCHANGE_DIRECT_TEST("test.smses.exchange.direct", "手机短信测试点对点"),
        MESSAGE_EMAIL_EXCHANGE_DIRECT("message.email.exchange.direct", "邮箱点对点"),
        MESSAGE_INFO_EXCHANGE_DIRECT("message.info.exchange.direct", "站内消息点对点"),
        SISS_LOG_EXCHANGE_DIRECT("siss.log.exchange.direct", "操作日志消息点对点")
        ;

        private String code;
        private String name;

        Exchange(String code, String name) {
            this.code = code;
            this.name = name;
        }

        public String getCode() {
            return code;
        }

        public String getName() {
            return name;
        }
    }

    /**
     * describe: 定义队列
     * creat_user: ygw
     * creat_date: 2018年9月27日
     **/
    public enum Queue {
        MESSAGE_SMS_QUEUE_TOPIC("message.sms.queue.topic", "手机短信topic消息队列"),
        MESSAGE_SMS_QUEUE_DIRECT("message.sms.queue.direct", "手机短信direct消息队列"),
        MESSAGE_EMAIL_QUEUE_DIRECT("message.email.queue.direct", "邮箱direct消息队列"),
        MESSAGE_SMS_QUEUE_DIRECT_TEST("test.smses.queue.direct", "邮箱direct消息队列测试"),
        MESSAGE_INFO_QUEUE_DIRECT("message.info.queue.direct", "站内消息direct消息队列"),
        SISS_LOG_QUEUE_DIRECT("siss.log.queue.direct", "操作日志消息direct消息队列")
        ;

        private String code;
        private String name;

        Queue(String code, String name) {
            this.code = code;
            this.name = name;
        }

        public String getCode() {
            return code;
        }

        public String getName() {
            return name;
        }

    }

    /**
     * describe: 定义路由键
     * creat_user: ygw
     * creat_date: 2018年9月27日
     **/
    public enum Key {
        MESSAGE_SMS_KEY_TOPIC("*.message.sms.key.topic.*", "手机短信topic消息队列key"),
        MESSAGE_SMS_KEY_DIRECT("message.sms.key.direct", "手机短信direct消息队列key"),
        MESSAGE_SMS_KEY_DIRECT_TEST("test.smses.key.direct", "手机短信direct测试消息队列key"),
        MESSAGE_EMAIL_KEY_DIRECT("message.email.key.direct", "邮箱direct消息队列key"),
        MESSAGE_INFO_KEY_DIRECT("message.info.key.direct", "站内消息direct消息队列key"),
        SISS_LOG_KEY_DIRECT("siss_log.key.direct", "操作日志消息direct消息队列key")
        ;

        private String code;
        private String name;

        Key(String code, String name) {
            this.code = code;
            this.name = name;
        }

        public String getCode() {
            return code;
        }

        public String getName() {
            return name;
        }

    }
}
